<style>
#EditProfilePaket legend input{
	width:16px;
	float:none;
	margin:0px 2px;
	padding:0px;
	border:none;
	background-color:transparent;
	cursor:pointer;
}
#EditProfilePaket li{
	margin:2px auto;
}
#EditProfilePaket li select{
	margin:0px;
	float:none;
}
#EditProfilePaket li input{
	margin:0px 5px;
	padding:0px;
	border:none;
	background-color:transparent;
	width:16px;
	cursor:pointer;
	float:none;
}
</style>
<div class="area" id="EditProfilePaket">
	<h2>Izmena paketa</h2>
	<form method="post" action="javascript:void(0)" onsubmit="profiliPaketiNewMakeItems(this,'profiliPaketiNewItemsListEdit'); submitForm(this,'artikli.php','POST','afterProfiliPaketiNew',1)">
		<input type="hidden" name="a" value="profili_paketi" />
		<input type="hidden" name="mod" value="save" />
		
		<input type="hidden" name="id" value="{{$id}}" />
		<label class="left" for="name">Naziv:</label>
		<input type="text" name="name" id="name" value="{{$name}}" />
		
		<br clear="all" />
		<label class="left" for="profile_type">Tip profila:</label>
		<select name="profile_type" id="profile_type">
			{{%loop start profile_type_id}}
			<option value="{{$profile_type_id}}" {{$profile_type_selected}}>{{$profile_type_code}}</option>
			{{%loop end}}
		</select>
		
		<br clear="all" />
		<label class="left" for="art_id">Artikl:</label>
		<select name="art_id" id="art_id" style="width:150px;">
			{{%loop start art_id}}
			<option value="{{$art_id}}" {{$art_selected}}>{{$art_name}}</option>
			{{%loop end}}
		</select>
		
		<br clear="all" />
		<label class="left" for="date_start">Važi od:</label>
		<input type="text" name="date_start" id="date_start" class="dateInput" value="{{$date_start}}" />
		<input type="button" class="datePicker" onclick="displayDatePicker('date_start',this)" />
		
		<br clear="all" />
		<label class="left" for="cena">Cena:</label>
		<input type="text" name="cena" id="cena" value="{{$price}}" />
		
		<br clear="all" />
		<fieldset>
			<input type="hidden" name="items" id="items" value="{{$items_raw}}" />
			<legend>Stavke <input type="button" class="novi" onclick="ProfiliPaketiNewAddItem(this)" value="" /></legend>
			<ol id="profiliPaketiNewItemsListEdit">
				{{%loop start item_id}}
				<li>
					{{$item_select}}
					<input type="button" class="delete" onclick="if(this.parentNode.parentNode.getElementsByTagName('li').length>1){this.parentNode.parentNode.removeChild(this.parentNode)}" />
				</li>
				{{%loop end}}
			</ol>
		</fieldset>
		
		<br clear="all" />
		<input type="submit" class="save" value="sačuvaj" />
	</form>
</div>